import scrapy
from imgsPro.items import ImgsproItem

class ImgSpider(scrapy.Spider):
    name = 'img'
    #allowed_domains = ['www.xxx.com']
    start_urls = ['https://sc.chinaz.com/tupian/xingganmeinvtupian.html']

    def parse(self, response):
        div_list = response.xpath('//div[@class="tupian-list"]/div')
        for div in div_list:
            src = 'https:'+div.xpath('./div/img/@data-original').extract_first()
            #print(src)
            item = ImgsproItem()
            item['src'] = src
            yield item


